const system = uni.getSystemInfoSync(); // 获取系统信息
export const getStatusBarHeight = () => {
	if (system.statusBarHeight) {
		return system.statusBarHeight
	} else {
		return 15;
	}
}; // 获取导航栏（刘海屏）的高度



export var getTitleBarHeight = () => {
	if (uni.getMenuButtonBoundingClientRect) {
		var {
			top,
			height
		} = uni.getMenuButtonBoundingClientRect(); // 获取小程序右边胶囊信息
		return height + (top - getStatusBarHeight()) * 2
	} else {
		return 50;
	}
};